package 数学问题;

import java.util.Scanner;

public class 分解质因数 {

        public static void main(String[] args) {
            Scanner scanner = new Scanner(System.in);
            int z = scanner.nextInt();
            int y = scanner.nextInt();

            for (int i = z; i <= y; i++) {
                if (issushu(i)){
                    System.out.println(i+"="+i);
                }else {
                    System.out.println(i+"="+heshu(i));
                }
            }
        }


        static String heshu(int num){
            String str = "";
            int i = 2;
            while (num!=1){
                if (issushu(i)&&num%i==0){
                    str = str +"*"+ i;
                    num = num/i;
                }else {
                    i++;
                }
            }
            return str.substring(1);
        }

        public static boolean issushu(int n){
            if (n==2||n==3){
                return true;
            }
            if (n%2==0){  //  是偶数就一定不是素数
                return false;
            }

            for (int i=3;i<=(int)Math.sqrt(n);i=i+2){ // 奇数+1为偶数，所以每次循环+2
                if (n%i==0) {return false;}
            }
            return true;
        }

    }

